The present disclosure relates to an image processing apparatus, an image processing method, and a program, and makes it possible to estimate a parallax with high accuracy from a plurality of images with different viewpoints.
In related art, to perform displaying or the like of a 3D image, three-dimensional information of real space is obtained. For example, Japanese Patent Application Laid-open No. 2001-103513 (hereinafter, referred to as Patent Document 1) discloses a method of estimating a distance to a desired subject by using the inverse-square law, which relates to illumination, that light emitted from a light source is lowered in inverse proportion to a square of a distance. For example, in Patent Document 1, when an image of an internal organ is taken, if there is methylene blue in the image, a light absorption characteristic changes in the area. The area is detected, and a luminance component value of the image is corrected, thereby estimating a depth distance.
Further, in Japanese Patent Application Laid-open No. 2012-065851 (hereinafter, referred to as Patent Document 2), a plurality of taken images with different viewpoints are used, thereby obtaining three-dimensional information of a real space. For example, one of methods of obtaining a parallax from a taken image at a left viewpoint and a taken image at a right viewpoint is a parallax estimation that uses stereo matching based on dynamic programming (hereinafter, referred to as “DP matching parallax estimation”). In the DP matching parallax estimation, generally, a degree of matching of corresponding points (or corresponding areas) between a taken image at a left viewpoint and a taken image at a right viewpoint is obtained on a pixel or block basis, and a parallax is estimated in such a manner that the degree of matching becomes optimum (maximum) for a pixel or block line as a whole. In such a DP matching parallax estimation, the parallaxes of the pixels or blocks are determined so that the entire line becomes optimum, so even if a noise is locally generated in an image, the parallax can be stably estimated generally. Further, it is also possible to estimate an absolute distance to a subject from the parallax estimated in Patent Document 2 and a camera parameter such as a line of sight.